/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */
/*
 * Nihongo
 * Copyright (C) Massimiliano Maniscalco 2011, 2012 <massimiliano@massiLinuxBook>
 * 
Nihongo is free software: you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the
 * Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 * 
 * Nihongo is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
 * See the GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License along
 * with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef _RESULTTESTKANJI_H_
#define _RESULTTESTKANJI_H_

#include "result_controller.h"
#include "result_kanji_model.h"

class Kanji;

class ResultTestKanji: public ResultController 
{
public:
	inline ResultTestKanji ( Glib::RefPtr<Gtk::Builder> _bldr, list<Kanji> *pk );
	inline ~ResultTestKanji () { delete _kanjiListColumns; }
	bool present_window ( void );
	unsigned int load_item_in_tree_view ( void );

protected:

private:
	list<Kanji> *_kanji;
	ResultKanjiModel* _kanjiListColumns;
	Glib::RefPtr<Gtk::ListStore> _kanjiListStore;

};

inline ResultTestKanji::
ResultTestKanji ( Glib::RefPtr<Gtk::Builder> _bldr, list<Kanji> *pk )
: _kanji ( pk )
{
	_kanjiListColumns = new ResultKanjiModel ();
	_kanjiListStore = Gtk::ListStore::create(*_kanjiListColumns);
	init_result_controller ( _bldr );
	connect_signals ();
}

#endif // _RESULTTESTKANJI_H_
